package object3.package3;

public class Duck extends Animal implements IAmphibian, IFlying{
    public Duck(String name) {
        super(name);
    }

    @Override
    public void fly() {
        System.out.println(name + "正在用两只翅膀飞行");
    }

    @Override
    public void run() {
        System.out.println(name + "正在用两条腿跑");
    }

    @Override
    public void swim() {
        System.out.println(name + "正在用两条腿游泳");
    }
}
